<template>
	<view class="brand-shop-details">
		<view class="shop-detail-item">
			<view class="detail-item-top">
				<view class="detail-item-title">
					<a href="#">{{ brand.name }}</a>
				</view>
				<view class="detail-item-img"><image :src="brand.list_pic_url" mode="widthFix"></image></view>
			</view>
			<view class="detail-item-text">{{ brand.simple_desc }}</view>
		</view>
	</view>
</template>

<script>
import { ApiBrandDetail } from '@/utils/api.js'
export default {
	data() {
		return {
			// 商品id
			cid: '',
			// 商品数据
			brand: {}
		}
	},
	methods: {},
	async onLoad(options) {
		this.cid = options.id
		let res = await ApiBrandDetail(this.cid)
		if (res.errno == 0) {
			this.brand = res.data.brand
		}
		console.log(this.brand)
		console.log(options.id)
	}
}
</script>

<style lang="scss">
.brand-shop-details {
	background-color: #efefef;
	height: 100vh;
}
.shop-detail-item {
	width: 750rpx;
	.detail-item-top {
		position: relative;
		height: 420rpx;
		.detail-item-title {
			position: absolute;
			z-index: 2;
			left: 50%;
			top: 50%;
			transform: translateX(-50%);
			a {
				color: #fff;
				font-size: 40rpx;
			}
		}
		.detail-item-img {
			width: 100%;
			image {
				width: 100%;
			}
		}
	}

	.detail-item-text {
		height: 200rpx;
		background-color: white;
		font-size: 36rpx;
		line-height: 52rpx;
		color: #666;
		text-align: center;
		padding: 20px 10px;
	}
}
</style>
